Skip to content

fix: repair CI lints and failing unit tests on master - #28

Merged
Liam Farrelly (lfarrel6) merged 1 commit into
masterfrom
claude/batch-dependency-bumps-ci-fix-bjrmef
Sep 3, 2026
Merged

fix: repair CI lints and failing unit tests on master#28
Liam Farrelly (lfarrel6) merged 1 commit into
masterfrom
claude/batch-dependency-bumps-ci-fix-bjrmef

Conversation

@lfarrel6

Copy link
Copy Markdown
Member

The Clippy and Unit Test jobs are red on master, independent of any
dependency bump. Three unrelated causes:

Clippy (stable is now 1.98, where unnecessary_unwrap also fires on
as_ref().unwrap(), plus useless_borrows_in_formatting and
useless_conversion hits):

  • active_model_ex.rs / model_ex.rs: bind the LitStr with a pattern
    instead of re-checking is_some() and unwrapping.
  • statement.rs, helper.rs, sea-orm-cli/commands/migrate.rs: drop the
    redundant borrows in write!/format! and the redundant into_iter().

Unit Test, cargo test --workspace failed to compile with
cannot find register_entity in sea_orm. DeriveEntity gates the registry
submission on sea-orm-macros' own entity-registry feature, but the
proc-macro crate is resolved once for the whole build while sea-orm is
not, so the macro can emit sea_orm::register_entity! into a sea-orm
built without the feature. sea-orm (and its sea-orm-sync mirror) now
provide a no-op register_entity! in that configuration, so the generated
code compiles either way.

cargo test --features entity-registry also failed to build the
integration tests: the submission named Entity as a value and hardcoded
that name, which breaks for an entity struct with fields, such as
tests/common/features/dyn_table_name.rs. Use the derived ident, and skip
entities that are not unit structs — those have no static schema to
register.

Finally, examples/quickstart goes back to being its own workspace.
As a member it unified sqlx-sqlite, runtime-tokio, schema-sync and
entity-registry into sea-orm's own test targets, which made the Unit
Test job compile and run the database integration tests, and those need a
DATABASE_URL that the job does not set.

Co-Authored-By: Claude Opus 5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_013LqKqpvKd1hWCpWvAZeQmn

The Clippy and Unit Test jobs are red on master, independent of any
dependency bump. Three unrelated causes:

Clippy (stable is now 1.98, where `unnecessary_unwrap` also fires on
`as_ref().unwrap()`, plus `useless_borrows_in_formatting` and
`useless_conversion` hits):

- `active_model_ex.rs` / `model_ex.rs`: bind the `LitStr` with a pattern
  instead of re-checking `is_some()` and unwrapping.
- `statement.rs`, `helper.rs`, `sea-orm-cli/commands/migrate.rs`: drop the
  redundant borrows in `write!`/`format!` and the redundant `into_iter()`.

Unit Test, `cargo test --workspace` failed to compile with
`cannot find register_entity in sea_orm`. `DeriveEntity` gates the registry
submission on `sea-orm-macros`' own `entity-registry` feature, but the
proc-macro crate is resolved once for the whole build while `sea-orm` is
not, so the macro can emit `sea_orm::register_entity!` into a `sea-orm`
built without the feature. `sea-orm` (and its `sea-orm-sync` mirror) now
provide a no-op `register_entity!` in that configuration, so the generated
code compiles either way.

`cargo test --features entity-registry` also failed to build the
integration tests: the submission named `Entity` as a value and hardcoded
that name, which breaks for an entity struct with fields, such as
`tests/common/features/dyn_table_name.rs`. Use the derived ident, and skip
entities that are not unit structs — those have no static schema to
register.

Finally, `examples/quickstart` goes back to being its own workspace.
As a member it unified `sqlx-sqlite`, `runtime-tokio`, `schema-sync` and
`entity-registry` into `sea-orm`'s own test targets, which made the Unit
Test job compile and run the database integration tests, and those need a
`DATABASE_URL` that the job does not set.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013LqKqpvKd1hWCpWvAZeQmn
@lfarrel6

Copy link
Copy Markdown
Member Author

Noticed CI was failing on an automated dependency patch for the JS example projects for unrelated Rust changes.

@lfarrel6
Liam Farrelly (lfarrel6) merged commit 29a87df into master Sep 3, 2026
38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants